package org.ranshiyan.ThreadUser;

import org.springframework.stereotype.Component;

public class ThreadUsr extends Thread{

    private int count=5;

    @Override
    synchronized public void run() {
        super.run();
        System.out.println(this.currentThread().getName()+"正在购票,剩余票数："+count+"张");
        count--;

    }
}
